<template>
  <div>
    <topper></topper>
    <index-header></index-header>
    <index-banner :list="bannerList"></index-banner>
    <index-gray-box></index-gray-box>
    <index-fatfooter></index-fatfooter>
  </div>
</template>
<script>
import IndexHeader from './components/IndexHeader'
import IndexBanner from './components/IndexBanner'
import Topper from '../../components/Topper'
import IndexFatfooter from './components/IndexFatfooter'
import IndexGrayBox from './components/IndexGrayBox'
import http from '../../base/api/http'
export default {
  name: 'Index',
  components: {
    Topper,
    IndexHeader,
    IndexBanner,
    IndexGrayBox,
    IndexFatfooter
  },
  data () {
    return {
      bannerList: [
      ]
    }
  },
  methods: {
    getHomeInfo () {
      http.requestQuickGet('/java/api/banner/findAllIndex').then((res) => {
        if (res.status === 0) {
          this.getHomeInfoSucc(res.data)
        }
      })
    },
    getHomeInfoSucc (res) {
      this.bannerList = res
    }
  },
  mounted () {
    this.getHomeInfo()
  }
}
</script>
<style>

</style>
